package com.wryyyyy.service.impl;

import com.wryyyyy.dto.Result;
import com.wryyyyy.entity.Device;
import com.wryyyyy.mapper.DeviceMapper;
import com.wryyyyy.service.IDeviceService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;

/**
 * <p>
 *  服务实现类
 * </p>
 *
 * @author wryyyyy
 * @since 2024-05-14
 */
@Service
public class DeviceServiceImpl extends ServiceImpl<DeviceMapper, Device> implements IDeviceService {
    @Resource
    private DeviceMapper deviceMapper;

    @Override
    public Result queryByFactory(String factoryId) {
        return Result.ok(deviceMapper.selectByFactory(factoryId));
    }
}
